From Eteinne.
authorrobertl <robertl@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Mon, 4 Jul 2005 17:41:44 +0000 (17:41 +0000)
committerrobertl <robertl@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Mon, 4 Jul 2005 17:41:44 +0000 (17:41 +0000)
RCS file: /cvsroot/gpsbabel/gpsbabel/vitosmt.c,v
I've found one of my valid vitosmt file fails the integrity test.  I
relaxed the validation a little.

RCS file: /cvsroot/gpsbabel/gpsbabel/waypt.c,v
Set some default values for new waypoint members.

RCS file: /cvsroot/gpsbabel/gpsbabel/lowranceusr.c,v
Discovered that the lowrance.c arg list is not null-terminated, causing
a GPF in exit_vecs .

gpsbabel/internal_styles.c
gpsbabel/lowranceusr.c
gpsbabel/vitosmt.c
gpsbabel/waypt.c

index 49efddea315c37b08e97a7b10e9645c0828a3741..706fbdace042d149125a88cdb138c30af78ce79a 100644 (file)
@@ -389,6 +389,8 @@ static char s_and_t[] =
 "#\n"
 
 "DESCRIPTION           Microsoft Streets and Trips 2002-2005\n"
+"EXTENSION               txt\n"
+
 
 "#\n"
 "# FILE LAYOUT DEFINITIIONS:\n"
index ace7f08902ce859c9a1e752dd931a370e1370861..9169b46bf0bdf6651efc7bbdb457a7b5fdd017ae 100644 (file)
@@ -228,7 +228,8 @@ arglist_t lowranceusr_args[] = {
        {"merge", &merge, "(USR output) Merge into one segmented track",
        NULL, ARGTYPE_BOOL },
        {"break", &seg_break, "(USR input) Break segments into separate tracks",
-       NULL, ARGTYPE_BOOL }
+       NULL, ARGTYPE_BOOL },
+       {NULL, NULL, NULL, NULL, 0}
 };
 
 static void
index 562aeab04a1218f81d65efdcb304e6e86105d8f3..e8d4878b801d82c5ec6dca78f752014823899586 100644 (file)
@@ -125,7 +125,6 @@ vitosmt_read(void)
        unsigned char   gpsvalid                =0;
        unsigned char   gpssats                 =0;
        int                             serial                  =0;
-       xml_tag *               xml_curr                =0;
        char                    buffer[80]              ="\0";
 
                
@@ -136,7 +135,7 @@ vitosmt_read(void)
        subversion      = ReadLong(infile);     /* 1000 */
        count           = ReadLong(infile);     /* n    */
        check1          = ReadLong(infile);     /* 0    */
-       check2          = ReadLong(infile);     /* n-1  */
+       check2          = ReadLong(infile);     /* not sure */
        check3          = ReadLong(infile);     /* n    */
 
        if (version!=vitosmt_version) {
@@ -152,7 +151,6 @@ vitosmt_read(void)
 
        if ((count!=check3)             ||
            (check1!=count-1)   ||
-               (check2!=0)                     ||
                (check3!=count)         ) {
 
                fatal("%s (%d) reading file. Invalid file header\n", 
@@ -277,7 +275,6 @@ vitosmt_waypt_pr(const waypoint *waypointp)
        struct tm*              tmstructp               =0;
        double                  seconds                 =0;
        double                  worknum                 =0;
-       xml_tag*                xmltagp                 =0;
 
        ++count;
        workbuffer = xcalloc(vitosmt_datasize,1);
index 87731cd6678923097e87fa5bd1b6aaa898aa0766..a8a179b8bf0d8ac86609c311359a9c1f0aea8c26 100644 (file)
@@ -138,6 +138,8 @@ waypt_new(void)
        wpt->altitude = unknown_alt;
        wpt->course = -999.0;
        wpt->speed = -999.0;
+       wpt->fix = fix_unknown;
+       wpt->sat = -1;
 
        return wpt;
 }